<template>
    <LayTag :type="bType" :variant="face" class="tag"><slot></slot></LayTag>
</template>

<script setup lang="ts">
import { LayTag } from '@layui/layui-vue';
import { computed } from 'vue';
import type { TagProps } from '@layui/layui-vue/types/component/tag/index.vue';
import { prepare_theme } from './index.ts';
import type { FaceType, ThemeType } from 'aoe';

const props = defineProps<{
    theme?: ThemeType;
    face?: FaceType;
}>();

const bType = computed<undefined | TagProps['type']>(() => prepare_theme(props.theme));
</script>

<style scoped></style>
